package com.teradyne.merlin2.ui.shared.models;

import java.io.Serializable;
import java.util.ArrayList;

public class OrderHeader implements Serializable {

	/**
	 * 
	 */
	private static final long serialVersionUID = 558461847918546412L;
	private int orderHeaderId;
	private String orderHeaderNo;
	private int customerNo;
	private String customerName;
	private boolean testerDown; // String
	private String customerSite;
	private String costCenter;
	private String paymentMethod; // ask if needed
	private String orderRequestNo;
	private String serialNo;
	private ArrayList<OrderLine> orderLines;
	private boolean validPartNo;
	private boolean validSerialNo;

	//

	private String billToCustomerNo;
	private String billToSiteNo;
	private String billToCustomerName;
	private String contactName;
	private String contactMiddleName;
	private String contactLastName;
	private String contactEmail;
	private String contactPhoneNo;
	// [DLS] Added for additional middle and last name - START (2011/10/05)
	private String attentionFirstName;
	private String attentionMiddleName;
	// [DLS] Added for additional middle and last name - END (2011/10/05)
	private String attentionLastName;
	private String attentionPhoneNo;
	private String platform;
	// private String attentionEmail;
	private String shipmethod;
	private String fieldServicePartType;
	private String fieldServiceFlag;
	private boolean isSPR;
	private String sPRHandlerName;
	private String sPRHandlerEmail;
	private String sPRHandlerPhoneNo;
	private String sPRHandlerLocation;
	private String onSiteNo;
	private String pip;
	private String pipContactName;
	private String pipContactEmail;
	private String pipContactPhoneNo;
	private String pipClarifySubcase;
	private String pipDefectiveSN;
	private String sPRcontactName;
	private String sPRcontactEmail;
	private String sPRcontactPhoneNo;
	private String specialInstruction;
	private String state;
	private String orderHeaderStatus;
	private String sprHandlerId;
	private String sprHandlerContactId;
	private String[] invalidReason;
	private String systemType;
	private String requestContactPartyId;
	private String requestContactDetailId;
	private int invalidReasonType;
	private String purchaseOrderNumber;
	private String[] agentInvalidReason;
	private boolean validSystemSerial;

	private boolean isCustomerOnHold;
	private boolean isWithSpendAuthorization;
	private boolean isNotValidCostCenter;
	private boolean isWithoutContactNo;

	private long requestFieldSvcDetailId;

	public boolean isNotValidCostCenter() {
		return isNotValidCostCenter;
	}

	public void setNotValidCostCenter(boolean isNotValidCostCenter) {
		this.isNotValidCostCenter = isNotValidCostCenter;
	}

	public OrderHeader() {
	};

	public String getOrderHeaderStatus() {
		return orderHeaderStatus;
	}

	public void setOrderHeaderStatus(String orderHeaderStatus) {
		this.orderHeaderStatus = orderHeaderStatus;
	}

	public int getOrderHeaderId() {
		return orderHeaderId;
	}

	public void setOrderHeaderId(int orderHeaderId) {
		this.orderHeaderId = orderHeaderId;
	}

	public void setSPR(boolean isSPR) {
		this.isSPR = isSPR;
	}

	public String getOrderHeaderNo() {
		return orderHeaderNo;
	}

	public void setOrderHeaderNo(String orderHeaderNo) {
		this.orderHeaderNo = orderHeaderNo;
	}

	public void setCustomerNo(int customerNo) {
		this.customerNo = customerNo;
	}

	public int getCustomerNo() {
		return customerNo;
	}

	public void setCustomerName(String customerName) {
		this.customerName = customerName;
	}

	public String getCustomerName() {
		return customerName;
	}

	public void setTesterDown(boolean testerDown) {
		this.testerDown = testerDown;
	}

	public boolean isTesterDown() {
		return testerDown;
	}

	public void setCustomerSite(String customerSite) {
		this.customerSite = customerSite;
	}

	public String getCustomerSite() {
		return customerSite;
	}

	public void setCostCenter(String costCenter) {
		this.costCenter = costCenter;
	}

	public String getCostCenter() {
		return costCenter;
	}

	public void setPaymentMethod(String paymentMethod) {
		this.paymentMethod = paymentMethod;
	}

	public String getPaymentMethod() {
		return paymentMethod;
	}

	public void setOrderRequestNo(String orderRequestNo) {
		this.orderRequestNo = orderRequestNo;
	}

	public String getOrderRequestNo() {
		return orderRequestNo;
	}

	public void setSerialNo(String serialNo) {
		this.serialNo = serialNo;
	}

	public String getSerialNo() {
		return serialNo;
	}

	public void setOrderLines(ArrayList<OrderLine> orderLines) {
		this.orderLines = orderLines;
	}

	public ArrayList<OrderLine> getOrderLines() {
		return orderLines;
	}

	public void setValidPartNo(boolean validPartNo) {
		this.validPartNo = validPartNo;
	}

	public boolean isValidPartNo() {
		return validPartNo;
	}

	public void setValidSerialNo(boolean validSerialNo) {
		this.validSerialNo = validSerialNo;
	}

	public boolean isValidSerialNo() {
		return validSerialNo;
	}

	public String getBillToCustomerNo() {
		return billToCustomerNo;
	}

	public void setBillToCustomerNo(String billToCustomerNo) {
		this.billToCustomerNo = billToCustomerNo;
	}

	public String getBillToSiteNo() {
		return billToSiteNo;
	}

	public void setBillToSiteNo(String billToSiteNo) {
		this.billToSiteNo = billToSiteNo;
	}

	public String getBillToCustomerName() {
		return billToCustomerName;
	}

	public void setBillToCustomerName(String billToCustomerName) {
		this.billToCustomerName = billToCustomerName;
	}

	public String getContactName() {
		return contactName;
	}

	public void setContactName(String contactName) {
		this.contactName = contactName;
	}

	public String getContactEmail() {
		return contactEmail;
	}

	public void setContactEmail(String contactEmail) {
		this.contactEmail = contactEmail;
	}

	public String getContactPhoneNo() {
		return contactPhoneNo;
	}

	public void setContactPhoneNo(String contactPhoneNo) {
		this.contactPhoneNo = contactPhoneNo;
	}

	// [DLS] Modified for additional middle and last name - START (2011/10/05)
	public String getAttentionFirstName() {
		return attentionFirstName;
	}

	public void setAttentionFirstName(String attentionFirstName) {
		this.attentionFirstName = attentionFirstName;
	}

	public String getAttentionMiddleName() {
		return attentionMiddleName;
	}

	public String getAttentionLastName() {
		return attentionLastName;
	}

	public void setAttentionLastName(String attentionLastName) {
		this.attentionLastName = attentionLastName;
	}

	public void setAttentionMiddleName(String attentionMiddleName) {
		this.attentionMiddleName = attentionMiddleName;
	}

	// [DLS] Modified for additional middle and last name - END (2011/10/05)

	public String getAttentionPhoneNo() {
		return attentionPhoneNo;
	}

	public void setAttentionPhoneNo(String attentionPhoneNo) {
		this.attentionPhoneNo = attentionPhoneNo;
	}

	public String getPlatform() {
		return platform;
	}

	public void setPlatform(String platform) {
		this.platform = platform;
	}

	public String getShipmethod() {
		return shipmethod;
	}

	public void setShipmethod(String shipmethod) {
		this.shipmethod = shipmethod;
	}

	public String getFieldServicePartType() {
		return fieldServicePartType;
	}

	public void setFieldServicePartType(String servicePartType) {
		this.fieldServicePartType = servicePartType;
	}

	/**
	 * @return the fieldServiceFlag
	 */
	public String getFieldServiceFlag() {
		return fieldServiceFlag;
	}

	/**
	 * @param fieldServiceFlag
	 *            the fieldServiceFlag to set
	 */
	public void setFieldServiceFlag(String fieldServiceFlag) {
		this.fieldServiceFlag = fieldServiceFlag;
	}

	public boolean getIsSPR() {
		return isSPR;
	}

	public void setIsSPR(boolean isSPR) {
		this.isSPR = isSPR;
	}

	public String getsPRHandlerName() {
		return sPRHandlerName;
	}

	public void setsPRHandlerName(String sPRHandlerName) {
		this.sPRHandlerName = sPRHandlerName;
	}

	public String getsPRHandlerEmail() {
		return sPRHandlerEmail;
	}

	public void setsPRHandlerEmail(String sPRHandlerEmail) {
		this.sPRHandlerEmail = sPRHandlerEmail;
	}

	public String getsPRHandlerPhoneNo() {
		return sPRHandlerPhoneNo;
	}

	public void setsPRHandlerPhoneNo(String sPRHandlerPhoneNo) {
		this.sPRHandlerPhoneNo = sPRHandlerPhoneNo;
	}

	public String getsPRHandlerLocation() {
		return sPRHandlerLocation;
	}

	public void setsPRHandlerLocation(String sPRHandlerLocation) {
		this.sPRHandlerLocation = sPRHandlerLocation;
	}

	public String getOnSiteNo() {
		return onSiteNo;
	}

	public void setOnSiteNo(String onSiteNo) {
		this.onSiteNo = onSiteNo;
	}

	public String getPip() {
		return pip;
	}

	public void setPip(String pip) {
		this.pip = pip;
	}

	public String getPipContactName() {
		return pipContactName;
	}

	public void setPipContactName(String pipContactName) {
		this.pipContactName = pipContactName;
	}

	public String getPipContactEmail() {
		return pipContactEmail;
	}

	public void setPipContactEmail(String pipContactEmail) {
		this.pipContactEmail = pipContactEmail;
	}

	public String getPipContactPhoneNo() {
		return pipContactPhoneNo;
	}

	public void setPipContactPhoneNo(String pipContactPhoneNo) {
		this.pipContactPhoneNo = pipContactPhoneNo;
	}

	public String getPipClarifySubcase() {
		return pipClarifySubcase;
	}

	public void setPipClarifySubcase(String pipClarifySubcase) {
		this.pipClarifySubcase = pipClarifySubcase;
	}

	public String getPipDefectiveSN() {
		return pipDefectiveSN;
	}

	public void setPipDefectiveSN(String pipDefectiveSN) {
		this.pipDefectiveSN = pipDefectiveSN;
	}

	public String getsPRcontactName() {
		return sPRcontactName;
	}

	public void setsPRcontactName(String sPRcontactName) {
		this.sPRcontactName = sPRcontactName;
	}

	public String getsPRcontactEmail() {
		return sPRcontactEmail;
	}

	public void setsPRcontactEmail(String sPRcontactEmail) {
		this.sPRcontactEmail = sPRcontactEmail;
	}

	public String getsPRcontactPhoneNo() {
		return sPRcontactPhoneNo;
	}

	public void setsPRcontactPhoneNo(String sPRcontactPhoneNo) {
		this.sPRcontactPhoneNo = sPRcontactPhoneNo;
	}

	public String getSpecialInstruction() {
		return specialInstruction;
	}

	public void setSpecialInstruction(String specialInstruction) {
		this.specialInstruction = specialInstruction;
	}

	public String getState() {
		return state;
	}

	public void setState(String state) {
		this.state = state;
	}

	public String getSprHandlerId() {
		return sprHandlerId;
	}

	public void setSprHandlerId(String sprHandlerId) {
		this.sprHandlerId = sprHandlerId;
	}

	public String getSprHandlerContactId() {
		return sprHandlerContactId;
	}

	public void setSprHandlerContactId(String sprHandlerContactId) {
		this.sprHandlerContactId = sprHandlerContactId;
	}

	public String[] getInvalidReason() {
		return invalidReason;
	}

	public void setInvalidReason(String[] invalidReason) {
		this.invalidReason = invalidReason;
	}

	public String getSystemType() {
		return systemType;
	}

	public void setSystemType(String systemType) {
		this.systemType = systemType;
	}

	public String getRequestContactPartyId() {
		return requestContactPartyId;
	}

	public void setRequestContactPartyId(String requestContactPartyId) {
		this.requestContactPartyId = requestContactPartyId;
	}

	public String getRequestContactDetailId() {
		return requestContactDetailId;
	}

	public void setRequestContactDetailId(String requestContactDetailId) {
		this.requestContactDetailId = requestContactDetailId;
	}

	public String getContactMiddleName() {
		return contactMiddleName;
	}

	public void setContactMiddleName(String contactMiddleName) {
		this.contactMiddleName = contactMiddleName;
	}

	public String getContactLastName() {
		return contactLastName;
	}

	public void setContactLastName(String contactLastName) {
		this.contactLastName = contactLastName;
	}

	public int getInvalidReasonType() {
		return invalidReasonType;
	}

	public void setInvalidReasonType(int invalidReasonType) {
		this.invalidReasonType = invalidReasonType;
	}

	public String getPurchaseOrderNumber() {
		return purchaseOrderNumber;
	}

	public void setPurchaseOrderNumber(String purchaseOrderNumber) {
		this.purchaseOrderNumber = purchaseOrderNumber;
	}

	public String[] getAgentInvalidReason() {
		return agentInvalidReason;
	}

	public void setAgentInvalidReason(String[] agentInvalidReason) {
		this.agentInvalidReason = agentInvalidReason;
	}

	public boolean isValidSystemSerial() {
		return validSystemSerial;
	}

	public void setValidSystemSerial(boolean validSystemSerial) {
		this.validSystemSerial = validSystemSerial;
	}

	public boolean isCustomerOnHold() {
		return isCustomerOnHold;
	}

	public void setCustomerOnHold(boolean isCustomerOnHold) {
		this.isCustomerOnHold = isCustomerOnHold;
	}

	public boolean isWithoutContactNo() {
		return isWithoutContactNo;
	}

	public void setWithoutContactNo(boolean isWithoutContactNo) {
		this.isWithoutContactNo = isWithoutContactNo;
	}

	public boolean isWithSpendAuthorization() {
		return isWithSpendAuthorization;
	}

	public void setWithSpendAuthorization(boolean isWithSpendAuthorization) {
		this.isWithSpendAuthorization = isWithSpendAuthorization;
	}

	public long getRequestFieldSvcDetailId() {
		return requestFieldSvcDetailId;
	}

	public void setRequestFieldSvcDetailId(long requestFieldSvcDetailId) {
		this.requestFieldSvcDetailId = requestFieldSvcDetailId;
	}

//	public void copy(PartRequestHeader partRequestHeader, OrderRequest businessOrderRequest) {
//
//		this.orderHeaderId = (int) partRequestHeader.getPartRequestHeaderId();
//		this.orderHeaderNo = String.valueOf(businessOrderRequest.getCustomerNumber());
//		this.customerNo = (int) businessOrderRequest.getCustomerNumber();
//		this.testerDown = partRequestHeader.getTesterDownFlag().equals("T") ? true : false;
//		this.attentionFirstName = partRequestHeader.getAttentionFirstName() != null ? partRequestHeader.getAttentionFirstName() : "";
//		this.attentionLastName = partRequestHeader.getAttentionLastName() != null ? partRequestHeader.getAttentionLastName() : "";
//		this.attentionPhoneNo = partRequestHeader.getAttentionPhone() != null ? partRequestHeader.getAttentionPhone() : "";
//		this.costCenter = partRequestHeader.getTerCostCenter() != null ? partRequestHeader.getTerCostCenter() : "";
//		this.paymentMethod = partRequestHeader.getPaymentMethod() != null ? partRequestHeader.getPaymentMethod() : "";
//		this.orderRequestNo = partRequestHeader.getPartRequestHeaderNumber() != null ? partRequestHeader.getPartRequestHeaderNumber() : "";
//		this.orderHeaderId = (int) partRequestHeader.getPartRequestHeaderId();
//		this.serialNo = partRequestHeader.getSystemSerialNumber() != null ? partRequestHeader.getSystemSerialNumber() : "";
//		this.orderHeaderStatus = partRequestHeader.getStatus() != null ? partRequestHeader.getStatus().getStatus() : "";
//		this.specialInstruction = partRequestHeader.getSpecialInstructions() != null ? partRequestHeader.getSpecialInstructions() : "";
//
//		final ArrayList<OrderLine> listOrderLine = new ArrayList<OrderLine>();
//		for (PartRequestDetail partRequestDetail : partRequestHeader.getPartRequestDetailList()) {
//			OrderLine orderLine = new OrderLine();
//
//			orderLine.copy(partRequestDetail, partRequestHeader);
//
//			listOrderLine.add(orderLine);
//		}
//	}

}
